<?php
if (eregi("mainfile.php",$_SERVER['SCRIPT_NAME'])) {
    #Header("Location: index.php");
    #die();
}


// SETTINGS
include("settings.inc.php");
    $table = new Tables;

// PHP
include("php/php.php");
    $php = new PHP;

// DATABASE
include("db/mysql.php");
    $db = new DB;
    // connect to the datbase
    $db->connect();

// USERS
#include("user/user.php");

// SESSIONS
include("session/session.php");
    $session = new Session;
    $session->init();

// LANGUAGE
include("lang/lang.php");
    $lang = new Lang;
    $lang->init(); // initialize the languages
    if ($_GET["newlang"] != "") { $lang->changeLang($_GET["newlang"]); } // check whether new language wished

// HTML
include("html/html.php");
    $html = new HTML;


// HTML FORMS
include("form/form.php");
    $html_form = new HTMLForm;


// TEMPLATE
include("template/template.php");
    $tpl = new Template;


// COMMON HTML TEXT
include("common/common.php");
    $common = new Common;


?>